import axios from 'axios';
import {ajax,base} from './config'

/**
*排版管理接口
*/
//工作组
export const getAllGroup = params => { return ajax.getMinData({url:`${base}userGroupController/getAllGroup.do`, params}); };
//部门人员
export const groupAndUserData = params => { return ajax.getMinData({url:`${base}groupUserController.do?groupAndUserDataGrid`, params}); };
//工作组排班管理提交
export const addGroupScheduiling = params => { return axios.post(`${base}tbScheduleController/addScl4groupOfgroupId.do`, params); };
//变电人员排班管理提交
export const addWorkerScheduiling = params => { return axios.post(`${base}tbScheduleController/addScl4group.do`, params); };
//获取个人排班数据/tbScheduleController/getPersonSch.do
// export const getScheduilingData = params => { return ajax.getMinData({url:`${base}tbTaskController/getCrewPerList.do`, params}); };
export const getScheduilingData = params => { return ajax.getMinData({url:`${base}tbScheduleController/getPersonSch.do`, params}); };
//获取部门排班数据tbScheduleController.do?getDepartSch
export const getDepartSch = params => { return ajax.getMinData({url:`${base}tbScheduleController/getDepartSch.do`, params}); };
//查看当日值班人员信息api/task/findScl4groupOfId2List.do
export const getCurrentWorker = params => { return ajax.getMinData({url:`${base}tbScheduleController/findScl4groupOfId2List.do`, params}); };
//删除值班人员tbScheduleController/delScl4per.do
export const delWorker = params => { return ajax.postData({url:`${base}tbScheduleController/delScl4per.do`, params}); };